<template>
  <div class="card">
    <div class="header">
      {{ date }}
    </div>
    <div class="dec">
      <div>生肖：{{ animalsYear }}</div>
      <div>忌：{{ avoid }}</div>
      <div>农历：{{ lunar }}</div>
      <div>宜：{{ suit }}</div>
      <div>星期：{{ weekday }}</div>
    </div>
    <div class="month_holiday">
      <div>最近的假期情况</div>
      <div
        v-for="(item, index) of holidayArr"
        :key="index"
      >
        <span>{{ item.name }}--</span>{{ item.desc }}
      </div>
    </div>

  </div>
</template>

<script>
export default {
  name: 'Card',
  props: ['date', 'animalsYear', 'avoid', 'lunar', 'suit', 'weekday', 'holidayArr']
}

</script>

<style scoped>
.card {
  width: 90vw;
  border-radius: 20px;
  box-shadow: 1px 1px 10px;
  overflow: hidden;
  background: #ecf0f1;
}
.header {
  height: 50vw;
  line-height: 50vw;
  font-size: 46px;
  text-align: center;
  background: #d35400;
}
.dec > div {
  box-sizing: border-box;
  border: 2px solid;
  margin: 4px;
  padding-left: 8px;
}
.month_holiday {
  min-height: 20vw;
  background: #27ae60;
  padding-bottom: 10vw;
  padding: 8px;
}
.month_holiday > :first-child {
  font-weight: 700;
  padding: 8px 4px;
}
.month_holiday > :last-child {
  margin: 4px 0;
}
.month_holiday span {
  font-weight: 700;
  margin: 4px;
}
</style>
